Skip to content

Conversation

@Wumpf
Copy link
Member

@Wumpf Wumpf commented Dec 19, 2025

Related

What

Allows drag & drop for encoded depth images rvl files into the Viewer.

@Wumpf Wumpf added include in changelog consider-patch PRs & issues that should be considered to be cherry-picked to a patch release branch. 📺 re_viewer affects re_viewer itself labels Dec 19, 2025
@github-actions
Copy link

github-actions bot commented Dec 19, 2025

Web viewer built successfully.

Result Commit Link Manifest
0c926fd https://rerun.io/viewer/pr/12287 +nightly +main

View image diff on kitdiff.

Note: This comment is updated whenever you push a commit.

@Wumpf Wumpf force-pushed the andreas/add-rvl-dataloader branch from 1ea9b7e to 8b238a3 Compare December 19, 2025 16:49
Allows drag & drop for encoded depth images `rvl` files into the Viewer.
@Wumpf Wumpf force-pushed the andreas/add-rvl-dataloader branch from 8b238a3 to 0c926fd Compare December 19, 2025 17:06
@Wumpf Wumpf requested a review from Copilot December 19, 2025 17:10
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds support for loading encoded depth images (particularly RVL format files) through drag-and-drop and log_from_file functionality in the Viewer.

Key changes:

  • Added a new extension module encoded_depth_image_ext with file loading utilities for encoded depth images
  • Implemented dataloader logic to handle depth image file extensions (.rvl and .png)
  • Extended supported file extensions to include depth image formats

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.

File Description
crates/store/re_sdk_types/src/archetypes/mod.rs Registers the new encoded_depth_image_ext module
crates/store/re_sdk_types/src/archetypes/encoded_depth_image_ext.rs Implements file loading methods for EncodedDepthImage archetype
crates/store/re_data_loader/src/loader_archetype.rs Adds load_depth_image function and integrates it into the loader pipeline
crates/store/re_data_loader/src/lib.rs Defines and exports SUPPORTED_DEPTH_IMAGE_EXTENSIONS constant

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

"pbm", "pgm", "png", "ppm", "tga", "tif", "tiff", "webp",
];

pub const SUPPORTED_DEPTH_IMAGE_EXTENSIONS: &[&str] = &["rvl", "png"];
Copy link

Copilot AI Dec 19, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The extension png appears in both SUPPORTED_IMAGE_EXTENSIONS and SUPPORTED_DEPTH_IMAGE_EXTENSIONS. This duplication could lead to ambiguity in file handling logic. Consider documenting why PNG is listed in both arrays or ensure the loader has clear precedence rules when a file extension matches multiple categories.

Copilot uses AI. Check for mistakes.
let rows = [{
let mut arch = re_sdk_types::archetypes::EncodedDepthImage::from_file_contents(contents);

if let Ok(format) = image::ImageFormat::from_path(filepath) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If it's a .png depth image, we should only accept it here if it contains a exactly 1 channel. RGB pngs should be handled by EncodedImage

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good point. Practically we won't get here because pngs are first handled by the image handler. Maybe we should stick to that explicitly, i.e. adding only rvl to the depth image extensions and then here also only handling rvl

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yea that sounds reasonable to me.

note that .rvl is not really an official file extension, and in the current state we only support the ROS specific format. So do we need this?

@ntjohnson1 ntjohnson1 merged commit 1dfd215 into main Dec 19, 2025
40 of 41 checks passed
@ntjohnson1 ntjohnson1 deleted the andreas/add-rvl-dataloader branch December 19, 2025 20:32
ntjohnson1 pushed a commit that referenced this pull request Dec 19, 2025
…agdrop) (#12287)

### Related

* Small follow-up to #11877

### What

Allows drag & drop for encoded depth images `rvl` files into the Viewer.
@ntjohnson1 ntjohnson1 removed the consider-patch PRs & issues that should be considered to be cherry-picked to a patch release branch. label Dec 22, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants